package com.inno.life.controller.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.inno.life.common.entity.PageDTO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.util.Date;

/**
 * MomentDTO
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class MomentDTO extends PageDTO implements Serializable {
    private static final long serialVersionUID = -46865094877806759L;
    /**
     * id
     */
    private Long id;
    /**
     * 发表人id
     */
    private Long userId;
    private String username;
    private String avatar;
    /**
     * 动态内容
     */
    private String content;
    /**
     * 图像url
     */
    private String imageUrl;
    /**
     * 评论数
     */
    private Integer commentCount;
    /**
     * 点赞数
     */
    private Integer likedCount;
    /**
     * 浏览数
     */
    private Integer viewCount;

    /**
     * 是否点赞
     */
    private Boolean liked;

    /**
     * 发布时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date createTime;

    /**
     * 后端用
     */
    private Long currentUserId;


}

